<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<script type="text/javascript" src="jquery-1.12.3.js"></script>
<script type="text/javascript">

/*
var test=function(){
	var readyList=jQuery.Deferred();
	
	setTimeout(function(){
		readyList.resolveWith( document, [ jQuery ] )
	}, 3000);
	//模拟长时间操作
	return readyList.promise();
}


test().done(function(){
	alert(789);
});
*/

function f1(){
	var a=10;
	var b=10;
	function f2(){
		console.log(a);
	}
	f2();
}
f1();

</script>
</head>
<body>

</body>
</html>